/**
 * Created by Administrator on 14-2-10.
 */
var mongoose = require('mongoose');
var timestamps = require('mongoose-timestamp');//(给Model自动添加createdAt和updatedAt):

var Schema = mongoose.Schema,
    ObjectId = Schema.ObjectId;

// Schema 结构
var schema = new Schema({
    // _id:ObjectId, // default id
    orig_flg:Number,// 原始记录flg［1:未经过切换；0:经过切换］
    doc_id:Number, // 用户文档的id
    design_id:Number,// 设计模板的id
    map_id:Number,// 分页映射模版id
    tg_id:Number,// 提纲模版id
    thumb:String,// 模版首页预览图
});
schema.plugin(timestamps);

mongoose.model('TgUserHistoryModel', schema, 'TgUserHistory');
